        <table id="characterTable" class="table table-striped table-hover table-condensed table-bordered">
            <thead>
            <tr>
                <th>Server</th><th>Name</th><th>Gold</th><th>Last Seen</th><th><div>Last Gather</div></th><th>Nodes</th><th>Duration</th>
            </tr>
            </thead>
            <tbody>
    {% for char in chars %}

            <a href=''>
                <tr  {% if char.isOnline() %}  class="{% if char.isStuck() %}error {% else %}success {% endif %}" {% endif %}> 
                <td>{% if char.isOnline() %}<li style="color:rgb(250,250,250)" class="icon-bolt icon-2x"></li>{% endif %}{{char.server.name}}</td>
                <td>{{char.name}}</td>
                <td style="text-align: right">{{char.gold|number_format(0,',','.') }}</td>
                {% set hours = char.timeLastSeen() / (60*60) %}
                {% set min = (char.timeLastSeen() % (60*60)) / 60 %} 
                <td style="text-align: right">{{ hours | number_format(0)}}h{{ min | number_format(0)}}m</td>            
                <td style="text-align: right">{% if char.lastGather %} 
                        {% if char.timeSinceLastGather < 3600 %} 
                                {{char.timeSinceLastGather  | date('i:s')}} s 
                        {% else %} {% set hours = char.timeSinceLastGather/3600 %}
                                {{ hours  | number_format(0)}} h 
                        {% endif  %}
                   {% endif  %}
                        
                </td>
                <td>{% if char.lastSession is not null %}
                        {{ char.lastSession.getTotalNodes() }}
                    {% endif %}
                </td>
                <td>{% if char.lastSession is not null %}
                        {% if char.lastSession.getDuration < 3600 %} 
                                {{char.lastSession.getDuration  | date('i:s')}} s 
                        {% else %} {% set hours =  (char.lastSession.getDuration / 3600)  %}
                                {{ hours | number_format(0) }} h 
                        {% endif  %}
                     {% endif %}</td>
                <td>{% if char.lastSession is not null %} 
                      {% if char.lastSession.getDuration() %}
                            {% set nodeh =  char.lastSession.getTotalNodes() * 3600 / char.lastSession.getDuration() %}{{ nodeh | number_format(0,',','.') }}
                      {% endif %}
                    {% endif %}
                    </td>
                    
                <td><a href="{{ path('character_edit', { 'id': char.id }) }}"><li class="icon-edit pull-right"></li></td>
                {% if char.isOnline() %}
                <tr class="{% if char.isStuck() %}error {% else %}success {% endif %}">
                    <td></td>
                    <td colspan="8">
                    {{ char.lastSession.status }} - {{ char.lastSession.goal }}
                    </td>
                </tr>
                {% endif %}
                </tr>
                
            </a>
            </tr>
    {% else %}
        <p>There are no characters in the DB</p>
    {% endfor %}
</tbody>
</table>
